package org.example.common.model.vo.base;

import java.io.Serializable;
import java.util.List;
import java.util.Map;

import com.alibaba.fastjson.annotation.JSONField;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

/**
 * 统一返回VO
 *
 * @author
 */
@Getter
@Setter
@ToString
public class ResponseVO<T> implements Serializable {

    private static final long serialVersionUID = 8139402695940000141L;

    /**
     * 返回码
     */
    @JSONField(ordinal = 1)
    private String code;

    /**
     * 返回码描述
     */
    @JSONField(ordinal = 2)
    private String msg;

    /**
     * 业务数据对象
     */
    @JSONField(ordinal = 3)
    private T data;

    /**
     * 封装校验错误信息
     */
    @JSONField(ordinal = 4)
    private Map<String, List<String>> parameterError;
}
